/*
 * Copyright (c) 2006, 2022, webrx.cn All rights reserved.
 *
 */
package cn.webrx;

/**
 * <p>Project: jse2204 - C8
 * <p>Powered by webrx On 2022-09-07 17:25:56
 *
 * @author webrx [webrx@126.com]
 * @version 1.0
 * @since 17
 */
public class C8 {

    static {
        System.out.println("ss12");
        System.out.println("ss12");
        System.out.println("ss12");
        System.out.println("ss12");
        System.out.println("ss12");
    }
    public static int age = 18;

    public static int pf(int i) {
        return i * i;
    }


    /**
    * (1)声明方法
    */
    public void show() {
        System.out.println("ok - 中文");
    }

    public void show(String name) {
        System.out.println("Hello," + name);
    }

    public String shows(String name) {
        return String.format("Hello,%s", name);
    }

    public void exec() {
        //(2）执行调用 非静态方法 实例化对象
        C8 a = new C8();
        a.show();
        a.show("张三丰");
        System.out.println(a.shows("李丽"));
    }

    public static void main(String[] args) {

        System.out.println(age);
        System.out.println(pf(16));

        //(2）执行调用 非静态方法 实例化对象

        //C8 a = new C8();
        // a.show();
        //a.show("张三丰");
        //System.out.println(a.shows("李丽"));

        C8 b = new C8();
        b.exec();

    }
}
